/*
		* Author:	 Sander
		* Date:		 12-apr-2011
		* Name:		 ToneMapper
		* Version:	1.0
		*
		* This code is property of Sander blahblahblah copyright blahblah.
*/


package javaraytracer;

//PENDING:add function/property description
public class ToneMapper
{

	public ToneMapper()
	{

	}

	public int colorMap( Vec3 c )
	{
		int R = (int)(c.x * 255.0);
		int G = (int)(c.y * 255.0);
		int B = (int)(c.z * 255.0);
		int color = (255 << 24) + ((R > 255 ? 255 : R) << 16) + ((G > 255 ? 255 : G) << 8) + (B > 255 ? 255 : B);
		
		return color;
	}

}
